Skip to content

fix(proxy): unify eventless anchor poison settlement - #51

Merged
hongzexin merged 1 commit into
mainfrom
fix/bridge-poisoned-anchor-circuit
Aug 29, 2026
Merged

fix(proxy): unify eventless anchor poison settlement#51
hongzexin merged 1 commit into
mainfrom
fix/bridge-poisoned-anchor-circuit

Conversation

@hongzexin

Copy link
Copy Markdown

Summary

Unify eventless HTTP bridge failure settlement so the retry circuit itself owns poisoned-anchor clearing. This closes the reader/terminal mixed-order window where two eventless failures opened cooldown but the old durable anchor could still be re-injected.

Type of change

  • fix: — bug fix (no behavior change beyond the bug)

OpenSpec

  • This PR includes / updates an OpenSpec change
  • This PR touches a codex-faithful path and preserves upstream-equivalent behavior

Change directory: openspec/changes/unify-eventless-anchor-poison-settlement/

Changes

  • Reader, terminal, grouped-terminal, and stale-retirement paths share the attempt-scoped retry circuit.
  • Circuit-open poison settlement uses fenced durable anchor clear with idempotent duplicate handling.
  • Clear failure remains fail-closed across cooldown expiry and process restart; full replay can run unanchored while delta-only requests return 503.
  • Successful completed responses reset poison state.
  • Added mixed-order, duplicate-callback, clear-failure, restart-marker, and cooldown regression coverage.

Test plan

make lint
make typecheck
pnpm dlx @fission-ai/openspec@1.11.0 validate --specs
uv run pytest -q tests/unit/test_proxy_http_bridge.py
uv run pytest -q tests/integration/test_http_responses_bridge.py

Results: lint, typecheck, OpenSpec 57/57, unit 686 passed, integration 151 passed.

Source sidechat: 01a04ac6-27a1-74b3-88d3-f1ede3901184
Recovered from: d1f4fa4

Centralize reader, terminal, grouped-terminal, and stale-retirement eventless failures on the retry-circuit threshold. Fence durable anchor clearing, preserve fail-closed behavior after clear failures, and prevent stale anchor reinjection across cooldowns or process restarts.

Source sidechat: 01a04ac6-27a1-74b3-88d3-f1ede3901184

Recovered from: d1f4fa4
@hongzexin
hongzexin force-pushed the fix/bridge-poisoned-anchor-circuit branch from d87422c to 640c860 Compare August 29, 2026 08:12
@hongzexin
hongzexin merged commit c57ab32 into main Aug 29, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant